﻿<%@ Page Title="" Language="C#" MasterPageFile="~/resumemanager/resume.master" Inherits="WebManager.BasePage" %>

<%@ Import Namespace="TalentPools.BLL" %>
<%@ Import Namespace="TalentPools.Model" %>
<script runat="server">

    public int ResumeId
    {
        get
        {
            return Convert.ToInt32(ViewState["resumeId"]);
        }
        set
        {
            ViewState["resumeId"] = value;
        }
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        MyUserLogin();
        if (!IsPostBack)
        {
            Session["resumeId"] = Convert.ToInt32(Request.QueryString["id"]);
            ResumeId = Convert.ToInt32(Session["resumeId"]);
            lblResumeId.Text = ResumeId.ToString();
            DataBind(ResumeId);
        }
    }
    private void DataBind(int resumeId)
    {

        //绑定基本信息
        fvBaseInfo.DataSource = new checkresumeManager().getresumeByresumeid(resumeId);
        fvBaseInfo.DataBind();
        //绑定工作履历
        rpRecord.DataSource = new RecordManager().GetRecord(resumeId);
        rpRecord.DataBind();
        //绑定培训经历
        rpTraning.DataSource = new TrainingManager().GetTrains(resumeId);
        rpTraning.DataBind();
        //绑定自定义信息
        rpCustom.DataSource = new CustomManager().GetCustom(resumeId);
        rpCustom.DataBind();
        //绑定求职意向
        fvIntention.DataSource = new IntentionManager().GetIntentionByResumeId(resumeId);
        fvIntention.DataBind();
        //绑定技能
        fvSkill.DataSource = new SkillManager().GetSkill(resumeId);
        fvSkill.DataBind();
    }
    protected void lbtnEditBase_Click(object sender, EventArgs e)
    {
        Response.Redirect("EditBasemean.aspx");
    }

    protected void lbtnEditInten_Click(object sender, EventArgs e)
    {
        Response.Redirect("EditIntentionInfo.aspx");
    }

    protected void lbtnEditRecord_Click(object sender, EventArgs e)
    {
        Response.Redirect("EditRecordInfo.aspx");
    }

    protected void lbtnEditTraining_Click(object sender, EventArgs e)
    {
        Response.Redirect("EditTrainInfo.aspx");
    }

    protected void lbtnEditSkill_Click(object sender, EventArgs e)
    {
        Response.Redirect("EditSkillInfo.aspx");
    }

    protected void lbtnCustom_Click(object sender, EventArgs e)
    {
        Response.Redirect("EditCustomInfo.aspx");
    }
</script>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
    <style type="text/css">
        
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <div id="resumeMain">
        <table width="100%" border="0" style="text-align: left;" cellpadding="0" cellspacing="0">
            <tr>
                <td>
                    <table width="100%" border="0" cellpadding="0" cellspacing="0" style="background-image: url(images/bg_rem.gif);
                        height: 27px;">
                        <tr>
                            <td class="myqzzpTD">
                                <div class="STYLE4">
                                    基本信息（ID:<asp:Label ID="lblResumeId" runat="server" Text=""></asp:Label>）</div>
                            </td>
                            <td>
                                <div style="text-align: right; padding-right: 30px;">
                                    <asp:LinkButton ID="lbtnEditBase" runat="server" OnClick="lbtnEditBase_Click">修改</asp:LinkButton></div>
                            </td>
                        </tr>
                    </table>
                    <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
                        <tr>
                            <td width="64%" valign="bottom">
                                <asp:FormView ID="fvBaseInfo" runat="server" Width="100%">
                                    <ItemTemplate>
                                        <table width="100%" border="0" cellpadding="4" cellspacing="1" bordercolor="#FFFFFF"
                                            class="mytable">
                                            <tr>
                                                <td bgcolor="#F9F9F9" rowspan="4" style="width: 219px; height: 40px;">
                                                    <div style="margin-top: 0px; height: 40px; font-size: 40px; font-weight: bold;">
                                                        <%#Eval("name") %></div>
                                                </td>
                                                <td bgcolor="#FBFCEF" style="text-align: right; padding-right: 10px;">
                                                    <%# Eval("sex") %>
                                                    |
                                                    <%# Eval("marriage")%>
                                                    |
                                                    <%#WebManager.BasePage.SetTimeFormat(Convert.ToDateTime(Eval("birthday")))%>
                                                    | 户口：<%# WebManager.BasePage.SetHKPlace(Eval("HKPlace")) %>| 现居于<%#WebManager.BasePage.SetCity(Eval("city"))%></td>
                                            </tr>
                                            <tr>
                                                <td bgcolor="#FBFCEF" style="text-align: right; padding-right: 10px;">
                                                    工作经验：<%#Eval("workYear")%>|
                                                    <%#WebManager.BasePage.SetPoliState(Eval("politicsStatus"))%>
                                                    | 身份证：<%#WebManager.BasePage.SetCard(Eval("card"))%></td>
                                            </tr>
                                            <tr>
                                                <td bgcolor="#FBFCEF" style="text-align: right; padding-right: 10px;">
                                                    <%#WebManager.BasePage.SetPhone(Eval("cellphone"))%>（手机）
                                                </td>
                                            </tr>
                                            <tr>
                                                <td bgcolor="#FBFCEF" style="text-align: right; padding-right: 10px;">
                                                    Email：<%#WebManager.BasePage.SetEmail(Eval("email"))%></td>
                                            </tr>
                                        </table>
                                    </ItemTemplate>
                                </asp:FormView>
                            </td>
                        </tr>
                    </table>
                    <br />
                    <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" style="background-image: url(images/bg_rem.gif);
                        height: 27px;">
                        <tr>
                            <td class="myqzzpTD">
                                <div class="STYLE4">
                                    求职意向</div>
                            </td>
                            <td>
                                <div style="text-align: right; padding-right: 30px;">
                                    <asp:LinkButton ID="lbtnEditInten" runat="server" OnClick="lbtnEditInten_Click">修改</asp:LinkButton></div>
                            </td>
                        </tr>
                    </table>
                    <asp:FormView ID="fvIntention" runat="server" Width="100%">
                        <ItemTemplate>
                            <table border="0" align="center" cellpadding="4" cellspacing="1" style="background-color: #fff;
                                width: 100%; border-color: #fff;" class="mytable">
                                <tr>
                                    <td width="105" bgcolor="#F9F9F9">
                                        期望工作性质：
                                    </td>
                                    <td width="639" bgcolor="#FBFCEF">
                                        <%#Eval("jobCategory")%>
                                    </td>
                                </tr>
                                <tr>
                                    <td style="background-color: #F9F9F9;">
                                        期望从事职业：
                                    </td>
                                    <td style="background-color: #FBFCEF; height: 40px;">
                                        <%#Eval("profession")%>
                                    </td>
                                </tr>
                                <tr>
                                    <td bgcolor="#F9F9F9" style="padding-top: 0px;">
                                        期望从事行业：
                                    </td>
                                    <td colspan="3" bgcolor="#FBFCEF" height="100px">
                                        <%#Eval("industry")%>
                                    </td>
                                </tr>
                                <tr>
                                    <td bgcolor="#F9F9F9">
                                        期望工作地点：
                                    </td>
                                    <td colspan="3" bgcolor="#FBFCEF">
                                        <%#Eval("area")%>
                                    </td>
                                </tr>
                                <tr>
                                    <td bgcolor="#F9F9F9">
                                        期望月薪：
                                    </td>
                                    <td colspan="3" bgcolor="#FBFCEF">
                                        <%#Eval("pay")%>
                                    </td>
                                </tr>
                                <tr>
                                    <td bgcolor="#F9F9F9">
                                        目前状况：
                                    </td>
                                    <td colspan="3" bgcolor="#FBFCEF">
                                        <%#Eval("state")%>
                                    </td>
                                </tr>
                            </table>
                        </ItemTemplate>
                    </asp:FormView>
                    <br />
                    <table width="100%" border="0" cellpadding="0" cellspacing="0" style="background-image: url(images/bg_rem.gif);
                        height: 27px;">
                        <tr>
                            <td class="myqzzpTD">
                                <div class="STYLE4">
                                    工作经历</div>
                            </td>
                            <td>
                                <div style="text-align: right; padding-right: 30px;">
                                    <asp:LinkButton ID="lbtnEditRecord" runat="server" OnClick="lbtnEditRecord_Click">修改</asp:LinkButton></div>
                            </td>
                        </tr>
                    </table>
                    <asp:Repeater ID="rpRecord" runat="server">
                        <ItemTemplate>
                            <table width="100%" border="0" cellpadding="4" cellspacing="1" style="background-color: #fff;"
                                class="mytable">
                                <tr>
                                    <td width="200" bgcolor="#F9F9F9">
                                        <%# WebManager.BasePage.SetTimeFormat(Convert.ToDateTime(Eval("beginTime"))) %>-<%#WebManager.BasePage.SetTimeFormat(Convert.ToDateTime(Eval("endTime"))) %></td>
                                    <td bgcolor="#FBFCEF" style="width: 608px">
                                        <%#Eval("title") %>
                                    </td>
                                </tr>
                                <tr>
                                    <td bgcolor="#F9F9F9">
                                        &nbsp;
                                    </td>
                                    <td bgcolor="#FBFCEF">
                                        <%#Eval("content") %>
                                    </td>
                                </tr>
                                <tr>
                                    <td bgcolor="#F9F9F9">
                                        &nbsp;
                                    </td>
                                    <td bgcolor="#FBFCEF">
                                        <%#Eval("details") %>
                                    </td>
                                </tr>
                            </table>
                        </ItemTemplate>
                    </asp:Repeater>
                    <br />
                    <table width="100%" border="0" cellpadding="0" cellspacing="0" style="background-image: url(images/bg_rem.gif);
                        height: 27px;">
                        <tr>
                            <td class="myqzzpTD">
                                <div class="STYLE4">
                                    培训经历</div>
                            </td>
                            <td>
                                <div style="text-align: right; padding-right: 30px;">
                                    <asp:LinkButton ID="lbtnEditTraining" runat="server" OnClick="lbtnEditTraining_Click">修改</asp:LinkButton></div>
                            </td>
                        </tr>
                    </table>
                    <asp:Repeater ID="rpTraning" runat="server">
                        <ItemTemplate>
                            <table width="100%" border="0" cellpadding="4" cellspacing="1" bordercolordark="#FFFFFF"
                                class="mytable">
                                <tr>
                                    <td width="200" bgcolor="#F9F9F9">
                                        <%#WebManager.BasePage.SetTimeFormat(Convert.ToDateTime(Eval("beginTime"))) %>-<%# WebManager.BasePage.SetTimeFormat(Convert.ToDateTime(Eval("endTime"))) %></td>
                                    <td bgcolor="#FBFCEF" style="width: 608px">
                                        <%#Eval("tittle") %>
                                    </td>
                                </tr>
                                <tr>
                                    <td bgcolor="#F9F9F9">
                                        &nbsp;
                                    </td>
                                    <td bgcolor="#FBFCEF">
                                        <%#Eval("details") %>
                                    </td>
                                </tr>
                                <tr>
                                    <td bgcolor="#F9F9F9">
                                        获得证书：
                                    </td>
                                    <td bgcolor="#FBFCEF">
                                        <%#Eval("result") %>
                                    </td>
                                </tr>
                            </table>
                        </ItemTemplate>
                    </asp:Repeater>
                    <br />
                    <table width="100%" border="0" cellpadding="0" cellspacing="0" style="background-image: url(images/bg_rem.gif);
                        height: 27px;">
                        <tr>
                            <td class="myqzzpTD">
                                <div class="STYLE4">
                                    精通技能</div>
                            </td>
                            <td>
                                <div style="text-align: right; padding-right: 30px;">
                                    <asp:LinkButton ID="lbtnEditSkill" runat="server" OnClick="lbtnEditSkill_Click">修改</asp:LinkButton></div>
                            </td>
                        </tr>
                    </table>
                    <asp:FormView ID="fvSkill" runat="server" Width="100%">
                        <ItemTemplate>
                            <table width="100%" border="0" cellpadding="4" cellspacing="1" bordercolordark="#FFFFFF"
                                class="mytable">
                                <tr>
                                    <td bgcolor="#F9F9F9" style="text-align:left;"><%#Eval("Name") %></td>
                                </tr>
                            </table>
                        </ItemTemplate>
                    </asp:FormView>
                    <br />
                    <asp:LinkButton ID="lbtnCustom" runat="server" onclick="lbtnCustom_Click" >添加自定义信息</asp:LinkButton>
                    <asp:Repeater ID="rpCustom" runat="server">
                        <ItemTemplate>
                            <table width="100%" height="27" border="0" cellpadding="0" cellspacing="0" style="background-image: url(images/bg_rem.gif)">
                                <tr>
                                    <td class="myqzzpTD">
                                        <div class="STYLE4">
                                            <%#Eval("tittle") %></div>
                                    </td>
                                    <td>
                                        <div style="text-align: right; padding-right: 30px;">
                                            <a href="EditCustomInfo.aspx">修改</a></div>
                                    </td>
                                </tr>
                            </table>
                            <table width="100%" border="0" cellpadding="4" cellspacing="1" bordercolordark="#FFFFFF"
                                class="mytable">
                                <tr>
                                    <td width="153" bgcolor="#F9F9F9">
                                        <%#Eval("content") %>
                                    </td>
                                </tr>
                            </table>
                            <br />
                        </ItemTemplate>
                    </asp:Repeater>
                </td>
            </tr>
        </table>
    </div>
</asp:Content>
